import React,{Component} from 'react'
import InputBox from './components/InputBox.js'
import TodoBar from './components/TodoBar.js'
import './App.css';

class App extends Component{
  constructor(props){
    super(props)
    this.state = {
      todos:{}
    }
  }


  addTodo = (todo)=>{
    console.log(todo);
    this.setState({
      todo:todo
    })
  }

  render(){
    return(
      <div className="App">
        <InputBox addTodo={this.addTodo}/>
        <TodoBar todo={this.state.todo}/>
      </div>
    )
  }



}

export default App;

